﻿using System.Collections.Generic;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Web.Mvc;
using Nop.Web.Framework.Mvc;
using Nop.Web.Framework;

namespace Nop.Plugin.Pricing.PreciousMetals.Models
{
    public class PreciousMetalsDetailModel : BaseNopEntityModel
    {
        public int ProductVariantId { get; set; }

        [NopResourceDisplayName("Admin.Catalog.PreciousMetal.Enabled")]
        public bool Enabled { get; set; }

        [NopResourceDisplayName("Admin.Catalog.PreciousMetal.MetalType")]
        public int MetalType { get; set; }

        [NopResourceDisplayName("Admin.Catalog.PreciousMetal.QuoteType")]
        public int QuoteType { get; set; }

        [NopResourceDisplayName("Admin.Catalog.PreciousMetal.MathType")]
        public int MathType { get; set; }

        [NopResourceDisplayName("Admin.Catalog.PreciousMetal.LowerAmount")]
        public decimal LowerAmount { get; set; }

        [NopResourceDisplayName("Admin.Catalog.PreciousMetal.Weight")]
        public decimal Weight { get; set; }

        [NopResourceDisplayName("Admin.Catalog.PreciousMetal.WeightUnit")]
        public int WeightId { get; set; }

        public IEnumerable<SelectListItem> AvailableWeights { get; set; }

        [NopResourceDisplayName("Admin.Catalog.PreciousMetal.PercentMarkup")]
        [DisplayFormat(DataFormatString = "{0:F2}", ApplyFormatInEditMode = true)]
        public decimal PercentMarkup { get; set; }

        [NopResourceDisplayName("Admin.Catalog.PreciousMetal.FlatMarkup")]
        [DisplayFormat(DataFormatString = "{0:F2}", ApplyFormatInEditMode = true)]
        public decimal FlatMarkup { get; set; }

        [NopResourceDisplayName("Admin.Catalog.PreciousMetal.TierPriceType")]
        public int TierPriceType { get; set; }

        [NopResourceDisplayName("Admin.Catalog.PreciousMetal.ProductVariantTitle")]
        [ReadOnly(true)]
        public string ProductVariantTitle { get; set; }

        ///// <summary>
        ///// This is the base weight for display only
        ///// </summary>
        //public string BaseWeightIn { get; set; }

        /// <summary>
        /// This is the base currency for display only
        /// </summary>
        public string BaseCurrencyIn { get; set; }



        [NopResourceDisplayName("Admin.Catalog.PreciousMetal.PriceRounding")]
        public int PriceRounding { get; set; }


        [NopResourceDisplayName("Admin.Catalog.PreciousMetal.PriceRoundingType")]
        public int PriceRoundingType { get; set; }
    }
}
